void* heartbeat_thread(void *arg) {
	    ConnectionPool *pool = (ConnectionPool*)arg;
	        while (1) {
			        sleep(5); // 每5秒检测一次
				        
				        pthread_mutex_lock(&pool->lock);
					        for (int i = 0; i < pool->size; i++) {
							            if (mysql_ping(pool->connections[i]) != 0) {
									                    mysql_close(pool->connections[i]);
											                    pool->connections[i] = mysql_init(NULL);
													                    mysql_real_connect(pool->connections[i], ...);
															                }
								            }
						        pthread_mutex_unlock(&pool->lock);
							    }
		    return NULL;
}
